/*
	Header file that contains all the function prototypes for the 
	 initialization functions
*/
#ifndef INCLUSION_GUARD_INITIALIZATIONS_H
#define INCLUSION_GUARD_INITIALIZATIONS_H


#define TIME_SET_SW         PORTBbits.RB1
#define START_SET_SW        PORTBbits.RB2
#define SW_P                PORTBbits.RB5
#define SW_M                PORTBbits.RB4
#define MANUAL_SW           PORTBbits.RB0

#define GREEN_LEDS          LATAbits.LATA3
#define YELLOW_LEDS         LATAbits.LATA4
#define RED_LEDS            LATAbits.LATA5
#define LCD_BACKLIGHT       LATAbits.LATA6
#define OZAP                LATAbits.LATA2
#define HOSE_SW             PORTAbits.RA0
#define EXT_HOSE_SW         PORTAbits.RA1


//EEPROM addresses
#define LCD_CONTROL_BITS_ADDR   0
#define RUN_TIME_ADDR           1
#define START_TIME_ADDRH        2
#define START_TIME_ADDRL        3
#define LCD_CONTRAST_ADDR       4
#define LCD_INVERT_ADDR         5
#define LCD_BACKLIGHT_TIME_ADDR 6
#define LCD_BIAS_SYSTEM_ADDR    7
#define LCD_TEMPCO_ADDR         8
#define FILTER_MINUTES_COUNT_H  9
#define FILTER_MINUTES_COUNT_L  10
#define HOURS_24_ADDR           11


//random EEPROM addresses to hold the 'keys' indicating that the EEPROM
//  has been properly initialized
#define KEY_DATA1               64
#define KEY_DATA2               100



void interrupt_init(void);
void timer0_init(void);
void timer1_init(void);
void timer1_reset(void);
void timer2_init(void);
void port_init(void);
void LCD_init(void);
void custom_characters(void);
void oscillator_init(void);
void SPI_init(void);

#endif
